<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<link head-type='kod' href="<?php echo STATIC_PATH;?>images/icon/fav.png" rel="icon" type="image/x-icon">
	<title><?php echo LNG('common.copyright.name');?>-<?php echo LNG('common.install'); ?></title>
	<link href="<?php echo STATIC_PATH;?>style/lib/main.css" rel='stylesheet'>
	<link href="<?php echo STATIC_PATH;?>style/dist/main.css" rel='stylesheet'>
	<link href="<?php echo $installPath;?>static/index.css" rel='stylesheet'>
	<?php Hook::trigger('template.commonHeader');?>
</head>

<body>
	<div id="app">
		<div class="install-box">
			<div class="content-main-message">
				<div class="header">
					<img src="<?php echo $installPath;?>static/logo.png">
				</div>
				<div class="body">
					<div class="content-main">
						<?php $hide = $installFast ? 'hidden' : '';?>
						<div class="install-fast hidden" fast="<?php echo $installFast; ?>" auto="<?php echo $installAuto; ?>"></div>
						<div class="check-result">
							<div class="title-box"><?php echo $installFast ? LNG('admin.setting.system') : LNG('admin.install.install'); ?></div>
							<div class="progress-box">
								<!-- <div class="active"><span>使用协议</span><span class="btm-line"></span></div> -->
								<div class="active <?php echo $hide;?>" data="env"><span><?php echo LNG('common.env.check');?></span><span class="btm-line"></span></div>
								<div class="<?php echo $hide;?>" data="db"><span><?php echo LNG('admin.install.databaseSet'); ?></span><span class="btm-line"></span></div>
								<div class="<?php echo $installFast ? 'active' : '';?>" data="user">
									<span><?php echo LNG('admin.setting.account'); ?></span>
									<span class="btm-line"></span>
								</div>
							</div>
							<!-- <div class="step-box agreement">
								<div class="message-content">
									<div class=""></div>
								</div>
							</div> -->
							<div class="step-box env <?php echo $hide; ?>">
								<div class="message-content form-box">
									<div class="env-table">
										<div class="env-item-list">
											<?php foreach($envList as $key => $opt){
												echo '<p class="'.$key.'"><span class="w30 row-title">'.$opt['title'].'</span><span class="w20 row-value"></span><span class="w40 row-desc">'.$opt['text'].'</span><span class="w10 row-state"><i class="icon icon-loading"></i></span><span class="clear"></span></p>';
											} ?>
										</div>
										<div class="form-row panel-form-body clear"><hr></div>
										<div class="form-row form-target-save hidden">
											<div class="setting-title"></div>
											<div class="setting-content">
												<button class="form-save-button"><?php echo LNG('common.ok'); ?></button>
												<a class="help hidden" target="_blank" href="http://doc.kodcloud.com/v2/#/help/install"><?php echo LNG('explorer.editor.help'); ?></a>
											</div>
										</div>
									</div>
								</div>
							</div>
							<div class="step-box db hidden">
								<div class="message-content">
									<p class="info-alert info-alert-yellow hidden"><?php echo LNG('admin.install.dbWasSet'); ?></p>
									<div class="db-table"></div>
								</div>
							</div>
							<div class="step-box user <?php echo $installFast ? '' : 'hidden';?>" style="min-height:274px">
								<div class="message-content">
									<div class="user-table"></div>
								</div>
							</div>
							<div class="step-box msg hidden">
								<i class="font-icon success"></i>
								<div class="message-content">
									<div class='title'><?php echo LNG('admin.install.success'); ?></div>
									<div class='desc'></div>
								</div>
							</div>
						</div>
						<div class="link hidden"> 
							<?php echo str_replace('5s', '<em class="delay">5</em>s', sprintf(LNG('explorer.jumpAfterWhile'), 5, './')); ?>
						</div>
					</div>
				</div>
			</div>
			<div class="common-footer aero"></div>
		</div>
	</div>

	<script type="text/javascript"> 
		window.API_HOST = "<?php echo appHostGet();?>";
		window.STATIC_PATH = "<?php echo STATIC_PATH;?>";
	</script>
	<script src="<?php echo STATIC_PATH;?>app/vender/es3-profill.js"></script>
	<script src="<?php echo STATIC_PATH;?>app/dist/vendor.js"></script>
	<script src="<?php echo STATIC_PATH;?>app/dist/api.js"></script>
	<script src="<?php echo $installPath;?>index.js"></script>
	<?php Hook::trigger('templateCommonFooter');?>
</body>
</html>
